package com.fl.mybatisgenerator.demo;

public class lambdaTest {
    public static void main(String[] args) {
//        likes like = new Like();
        //匿名内部类
//        like.lambda();
//        like = new likes() {
//            @Override
//            public void lambda() {
//                System.out.println("lambda");
//            }
//        };
//        like.lambda();
       likes like = (i) -> {
            System.out.println("lambda2"+i);
        };
        like.lambda(10);
    }
}
//函数式接口
interface likes {
    void lambda(Integer i);
};

//class Like implements likes {
//
//    @Override
//    public void lambda() {
//        System.out.println("函数");
//    }
//}